<ui:composition xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core"
	xmlns:p="http://primefaces.org/ui" template="/template/template.xhtml"
	xmlns:c="http://java.sun.com/jsp/jstl/core">
	<ui:define name="head">
		<style type="text/css">
body {
	margin: 0;
	overflow: hidden;
	background: #fff;
}

#map {
	position: relative;
	height: 510px;
	border: 1px solid #3473b7;
}

#toolbar {
	position: relative;
	padding-top: 5px;
	padding-bottom: 10px;
}
/* 搜索样式 */
.search-box {
	position: absolute;
	top: 10px;
	right: 5px;
	width: 300px;
	background-color: #fff;
	z-index: 9999;
}

.hoverDiv {
	position: absolute;
	z-index: 9999;
	background-color: rgba(225, 255, 255, 0.9);
	display: none;
	border-color: ridge;
	border-radius: 5px;
	border-width: 5px;
	-webkit-transition-property: all;
	transition-property: all;
	-webkit-transition-duration: 0.5s;
	transition-duration: 0.5s;
	-webkit-transition-timing-function：ease;
	transition-timing-function：ease;
}

.toolbar-box {
	position: absolute;
	top: 20px;
	right: 316px;
	z-index: 2000;
	background-color: #fff;
}

.timeline-box {
	position: absolute;
	bottom: 20px; margin 0;
	z-index: 2000;
	/* background-color: #0490E8; */
	background-color: #87CEFA;
	width: 100%
}

.timelineTitle {
	position: absolute;
	bottom: 75px; margin 20px;
	z-index: 2000;
	/* background-color: #0490E8; */
	background-color: #87CEFA;
	/* background-color:transparent; */
	width: 100%
}
/*特维分析*/
#info {
	padding: 0px;
}

#statistics .info-box-icon {
	font-size: 20px;
}

#statistics p:nth-child(2) {
	font-size: x-large;
}

#statistics p:nth-child(1) {
	font-size: large;
}
/* 风险评估 */
#riskDiv {
	padding: 10px 20px;
}

#riskDiv a {
	color: black;
}

#riskDiv li i {
	color: blue;
	font-size: 22px;
}

#riskDiv .riskSelected {
	background-color: #FAF0E6;
}

#riskDiv .riskSelected a, #riskDiv .riskSelected i, .riskSelected {
	color: red;
}
/* 风险告警 */
#riskAlarmDiv {
	display: none;
	position: absolute;
	right: 15px;
	top: 70px;
	z-index: 2000;
	width: 350px;
}

.btn-collapse {
	position: absolute;
	top: -10px;
	z-index: 2000;
	opacity: 0.8;
	float: left;
	margin-right: -10px;
	margin-left: 10px;
	min-width: 60px;
	background-color: #1599E8;
	color: #fff;
	display: block;
	width: 60px;
	box-sizing: border-box;
	height: 10px;
	margin-bottom: 0px;
}

.btn-collapse-min {
	position: absolute;
	top: -10px;
	z-index: 2000;
	float: left;
	margin-right: -10px;
	margin-left: 10px;
	min-width: 30px;
	background-color: #1599E8;
	color: #fff;
	display: block;
	width: 30px;
	box-sizing: border-box;
	height: 30px;
	margin-bottom: 0px;
	border-radius: 3px;
	line-height: 27px;
	text-align: center;
}
/* 按钮组样式 */
.btn-box {
	position: absolute;
	top: 60px;
	left: 0;
	z-index: 2000;
	opacity: 0.8;
}

.btn-box-left {
	float: left;
	margin-right: -10px;
}

.btn-box-right {
	float: right;
}

.btn-app {
	min-width: 60px;
	background-color: #1599E8;
	color: #fff;
}

.btn-col {
	display: block;
	box-sizing: border-box;
	margin-bottom: 0px;
	width: 60px;
}

.btn-app:focus, .btn-app.focus, .btn-app:hover, .btn-app:active, .btn-app.active {
	color: yellow;
	background-color: #0490E8;
}

/*按钮不变色*/
.notChangeColor:focus, .notChangeColor.focus, .notChangeColor:hover, .notChangeColor:active,
	.notChangeColor.active {
	color: white;
}

.btn-app>.badge {
	position: absolute;
	top: -3px;
	right: -1px;
	font-size: 10px;
	font-weight: 400;
}

.btn>.badge {
	position: absolute;
	top: -8px;
	right: -2px;
	font-size: 10px;
	font-weight: 400;
}

.row {
	margin-left: -15px !important;
}

.weatherBox {
	width: 350px; /* min-height:40px; border:1px solid #ccc; */
	background-color: #f5f5f5;
	position: absolute;
	top: 70px;
	right: 15px;
	z-index: 2000;
	border-radius: 4px;
}

.panel-group {
	margin-bottom: 0;
}

.panel-body {
	padding: 5px;
	padding-top: 0;
}
/* table.dataTable thead > tr > th {
    padding: 8px 10px;
} */
.col-sm-5, .col-sm-7 {
	text-align: center;
	width: 100%;
}

div.col-sm-7>.dataTables_paginate {
	text-align: center;
	margin-top: 4px;
}

.dataTables_scrollHeadInner {
	width: 100% !important;
}

.dataTables_scrollBody {
	width: 100% !important;
}

#datatable {
	width: 100% !important;
	/*word-wrap:break-word; word-break:normal;*/
	word-break: break-all;
}

.typeahead {
	width: 300px;
	clear: both;
	max-height: 400px;
	overflow-y: auto;
}

table {
	border-bottom: 1px solid #f4f4f4;
	width: 319px !important;
	/* width: 100% !important; */
}

.table>thead>tr>th {
	vertical-align: middle;
}

.dataTables_wrapper.no-footer .dataTables_scrollBody {
	border-bottom: 0;
}

table.dataTable thead>tr>th {
	padding-right: 0 !important;
	border-bottom-width: 1px;
}

.marquee {
	background: url(/resources/img/top_bottom.png) !important;
	color: #333;
	font-weight: 700;
}

.toggle1s {
	transition: all 1s;
	-moz-transition: all 1s; /* Firefox 4 */
	-webkit-transition: all 1s; /* Safari and Chrome */
	-o-transition: all 1s; /* Opera */
}

.bottomMarquee {
	position: absolute !important;
	bottom: 0;
	background: url(/resources/img/typhoon/lishi_bg.png) !important;
	font-weight: 700;
	z-index: 2000;
	font-size: 18px !important;
	height: 30px !important;
}

#bottomMarquee .str_move {
	top: 5px !important;
}

.box-header {
	padding: 0;
}

.box-header>.box-tools {
	top: 0;
}

.h4margin {
	margin-left: 15px;
}

.panel-group .panel {
	border-radius: 0;
	margin-bottom: 1px;
}

.panel-heading {
	border-radius: 0 !important;
}

.panel-title {
	border-bottom: 1px solid #ddd !important;
}

.panel-group .panel+.panel {
	margin-top: -1px !important;
}

.panel {
	border: none;
}

.btn-box-tool {
	padding: 10px;
}

ul, li {
	margin: 0;
	padding: 0;
	list-style-type: none;
}

.btn-box ul li {
	position: relative;
}

.btn-box ul li ul li {
	float: none;
}

.btn-box ul li ul {
	position: absolute;
	left: 60px;
	top: 0;
	display: none;
}

/* .btn-box #btnBoxLeft li:hover ul {
	display: block;
}

.btn-box #btnBoxRight li:hover ul {
	display: block;
} */
.btn-second {
	background-color: #00C0EF;
}

.form-control[readonly] {
	background-color: white
}

.bottom-title {
	/* width: 150px;
	height: 40px;
	padding: 2px 2px 0 2px;
	background: #09c;
	border-radius: 4px 4px 0 0; */
	margin-left: 10px;
	font-size: 12px;
	color: #fff;
	cursor: pointer;
	float: left;
	position: absolute;
	bottom: 115px;
	z-index: 1250;
}

.left_top {
	position: absolute;
	top: 10px;
	left: 80px;
	z-index: 1500;
	display: none;
	width: 400px;
	padding-left: 5px !important;
	background-color: rgba(232, 239, 245, 0.7);
}

.smFramedCloudPopupContent {
	overflow: hidden !important;
	padding: 0 !important;
}

.smPopupContent {
	overflow: hidden !important;
	padding: 0 !important;
}

.btn-list {
	position: absolute;
	z-index: 9999;
	top: 20px;
	left: 10px;
}

.newEquipmentAlarm {
	position: absolute;
	top: 600px;
	left: 0;
	z-index: 2000;
	opacity: 0.8;
}

#equipmentLayer {
	padding: 10px;
	min-height: 100px;
	max-height: 150px;
	line-height: 22px;
	font-weight: 400;
	overflow: auto;
	color: #000;
	font-weight: 400;
	line-height: 22px;
	font-weight: 400;
}

#equipmentLayer li {
	border-bottom: 1px solid #f2f2f2;
	height: 35px;
	line-height: 35px;
}
</style>

		<link href='/resources/bootstrap/css/bootstrap-responsive.min.css' rel='stylesheet' />
		<link href='/resources/plugins/datatables/dataTables.bootstrap.css' rel='stylesheet' />
		<link href='/resources/bootstrap/css/bootstrap-datetimepicker.min.css' rel='stylesheet' />
		<link href='/resources/css/panelTablesUtil.css' rel='stylesheet' />
		<link href='/resources/css/liMarquee.css' rel='stylesheet' />
		<link href='/resources/css/map/map.css' rel='stylesheet' />

		<script src="/resources/js/jquery.js"></script>
		<script src="/resources/plugins/SuperMap/libs/SuperMap.Include.js"></script>
		<script src="/resources/plugins/SuperMap/graph/Bar3D.js"></script>
		<script src="/resources/plugins/SuperMap/graph/Pie.js"></script>
		<script src="/resources/js/jquery.liMarquee.js"></script>
		<script>
		function showChildren(obj){
			var status = $(obj).next('ul').css("display");
			$('.sub-menu').hide();
			if (status &amp;&amp; status == 'block'){
				$(obj).next().css("display",'none');
			} else {
				$(obj).next().css("display",'block');
			}
		}
		</script>
	</ui:define>
	<ui:define name="content">
		<div id="map" class="full-content">
			<div class="marquee" id="marquee" style="display: none;"></div>
			<!-- 设备新增公告 -->
			<div id="newEquipmentAlarm" class="newEquipmentAlarm">
				<div class="layui-layer-title"
					style="font-size: 14px; cursor: move; background: #1587CB; color: #fff; border: none;">
					设备新增公告<a class="pull-right" style="text-decoration: underline;text-indent:2em; color: #fff;"
						onclick="hideNewEquipmentAlarm()">关闭</a>    <a class="pull-right" style="text-decoration: underline; color: #fff;"
						onclick="showNewEquipmentAlarmMsg()">详情</a>
				</div>
				<div id="equipmentLayer">
					<ul id="equipmentUL" style="list-style: none; padding: 0;">
						<!-- <li><span
							style="display: inline-block; width: 300px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;">ceshi
								ddddd</span><span class="pull-right" style="display: inline-block;">2019-06-21</span></li> -->
					</ul>
				</div>
			</div>
			<div id="bottomMarquee" class="bottomMarquee"></div>
			<div id="leftTopDiv" class="box box-solid bg-light-blue-gradient col-md-3 left_top no-padding">
				<div class="box-header with-border">
					<h4 id="leftTopDivTitle"></h4>
					<div class="box-tools pull-right">
						<button type="button" class="btn btn-primary btn-sm pull-right" data-widget="collapse"
							style="margin-right: 5px;" data-original-title="Collapse">
							<i class="fa fa-minus"></i>
						</button>
					</div>
				</div>
				<div id="leftTopDivBody" class="box-body"></div>
			</div>
			<div id="hoverDiv" class="hoverDiv"></div>
			<div id="div_timeline" class="timeline-box" style="display: none;">
				<h3 id="title_timeline" class="font-family:SimHei" style="color: white"></h3>
				<div id="chart_timeline" style="height: 50px;"></div>
			</div>
			<div id="hiddenDiv" style="display: none;"></div>
			<div id="faultAlarmDiv"></div>
			<div class="bottom-title" id="bottom_title" style="display: none;"></div>
			<div id="bottomDiv"
				style="display: none; height: 116px; bottom: 0px; width: 100%; position: absolute; z-index: 2000;">
				<div
					style="background-image: url(/resources/img/typhoon/lishi_bg.png); clear: both; height: 116px; width: 100%; overflow: hidden;">
					<div style="height: 3px; background: #3c8dbc; clear: both;"></div>
					<div id="bottomTimeline"
						style="height: 100px; width: 100%; display: inline; position: absolute; z-index: 4;"></div>
					<div
						style="height: 16px; background: #3c8dbc; position: absolute; bottom: 0; width: 100%; z-index: 0;">
					</div>
				</div>
			</div>
			<div class="input-group margin search-box">
				<input type="text" id="input_search" class="form-control" data-provide="typeahead"
					data-items="100" /> <span class="input-group-btn">
					<button type="button" id="btn_search" onclick="searchObj();" class="btn btn-info btn-flat">#{lang.souSuoAnNiu}</button>
				</span>
			</div>
			<div class="btn-group toolbar-box ">
				<button type="button" title="测距" onclick="distanceMeasure()" class="btn btn-default btn-flat">
					<img src="/resources/img/map/ruler.png"></img>
				</button>
				<button type="button" title="矩形查询" onclick="drawQueryRectangle()"
					class="btn btn-default btn-flat">
					<i class="fa fa-clone"></i>
				</button>
				<button type="button" title="清除" onclick="clearAll(true)" class="btn btn-default btn-flat">
					<i class="fa fa-repeat"></i>
				</button>
				<button type="button" title="擦除搜索结果" onclick="clearSearchObj();"
					class="btn btn-default btn-flat">
					<i class="fa fa-eraser" />
				</button>
			</div>
			<div id="affectObjDiv" class="weatherBox box box-success"
				style="display: none; padding-left: 8px; background-color: white;"></div>
			<!-- 蓝色竖向浮动工具条 -->
			<div id="btnBox" class="btn-box">
				<ul class="btn-box-left">
					<li><a id="collapseBtn" class="btn-collapse" data-toggle="collapse" href="#btnBoxLeft"
						onclick="changeStatus(this)"> <img id="myLogo" />
					</a></li>
				</ul>
				<ul class="btn-box-left collapse in " id="btnBoxLeft">
					<c:forEach var="item" items="#{indexPageMenuManagerController.funcList}">
						<li><c:choose>
								<c:when test="#{item.event!=null}">
									<a href="#{item.url}" onclick="showChildren(this);#{item.event}"
										class="btn btn-app btn-col"> <span id="#{item.id}num" class="badge bg-red"></span> <i
										class="#{item.icon}"></i>#{indexPageMenuManagerController.getLocaleString(item)}
									</a>
								</c:when>
								<c:when test="#{item.event==null}">
									<a href="#{item.url}" onclick="showChildren(this)"
										class="btn btn-app btn-col notChangeColor" style="cursor: default"> <span
										id="#{item.id}num" class="badge bg-red"></span> <i class="#{item.icon}"></i>#{indexPageMenuManagerController.getLocaleString(item)}
									</a>
								</c:when>
							</c:choose> <c:if test="#{item.subFunctions.size() != 0}">
								<ul class="sub-menu">
									<c:forEach var="sitem" items="#{item.subFunctions}">
										<li><a href="#{sitem.url}" onclick="#{sitem.event}"
											class="btn btn-app btn-col btn-second"> <span id="#{sitem.id}num"
												class="badge bg-red"></span> <i class="#{sitem.icon}"></i>#{indexPageMenuManagerController.getLocaleString(sitem)}
										</a></li>
									</c:forEach>
								</ul>
							</c:if></li>
					</c:forEach>
				</ul>
			</div>
			<!-- 横向白色按钮条-->
			<!-- <div id="transverseBtnBox" class="btn-list" style="display:none !important;">
				<c:forEach var="item" items="#{indexPageMenuManagerController.funcList}">
					<div class="btn-group">
						<c:choose>
							<c:when test="#{item.event != null}">
								<a href="#{item.url}" onclick="#{item.event}" data-toggle="dropdown"
									class="btn btn-default btn-sm dropdown-toggle"> <span id="#{item.id}num"
									class="badge bg-red"></span> <i class="#{item.icon}"></i>
									#{indexPageMenuManagerController.getLocaleString(item)} <c:if
										test="#{item.subFunctions.size() != 0}">
										<span class="caret"></span>
									</c:if>
								</a>
							</c:when>
							<c:when test="#{item.event == null}">
								<a href="#{item.url}" data-toggle="dropdown" class="btn btn-default btn-sm dropdown-toggle">
									<span id="#{item.id}num" class="badge bg-red"></span> <i class="#{item.icon}"></i>
									#{indexPageMenuManagerController.getLocaleString(item)} <c:if
										test="#{item.subFunctions.size() != 0}">
										<span class="caret"></span>
									</c:if>
								</a>
							</c:when>
						</c:choose>
						<c:if test="#{item.subFunctions.size() != 0}">
							<ul class="dropdown-menu" role="menu">
								<c:forEach var="sitem" items="#{item.subFunctions}">
									<li><a href="#{sitem.url}" onclick="#{sitem.event}"> <i class="#{sitem.icon}"></i>
											#{indexPageMenuManagerController.getLocaleString(sitem)} <span id="#{sitem.id}num"
											class="badge bg-red"></span>
									</a></li>
								</c:forEach>
							</ul>
						</c:if>
					</div>
				</c:forEach>
			</div> -->
		</div>
		<div id="modal" />
		<span id="hiddenSpan" style="display: none;" />
	</ui:define>
	<ui:define name="contentend">
		<!-- 插件 -->
		<script src="/resources/plugins/echarts/echarts.min.js"></script>
		<script src="/resources/plugins/datatables/jquery.dataTables.min.js"></script>
		<script src="/resources/plugins/datatables/dataTables.bootstrap.min.js"></script>
		<script src="/resources/plugins/jQueryUI/jquery-ui.js"></script>
		<script src="/resources/bootstrap/js/bootstrap-datetimepicker.min.js"></script>
		<script src="/resources/plugins/snapsvg/snap.svg.js"></script>

		<!-- util -->
		<script src="/resources/js/array-util.js"></script>
		<script src="/resources/js/tables/mytable.js"></script>
		<script src="/resources/js/mycharts/timeline.js"></script>
		<script src="/resources/js/mycharts/categoryBarChart.js"></script>
		<script src="/resources/js/mycharts/pieChart.js"></script>
		<script src="/resources/js/tables/panelTablesUtil.js"></script>
		<script src="/resources/js/mypopup/popup.js"></script>
		<script src="/resources/js/objectId.js"></script>
		<script src="/resources/js/supermapUtil.js"></script>
		<script src="/resources/js/date-util.js"></script>

		<!-- 业务 -->
		<script src="/ui/map/mapCluster.js"></script>
		<script src="/ui/map/faultAlarmMan.js?v=0.0.2"></script>
		<script src="/ui/map/protectionActRatio.js"></script>
		<script src="/ui/map/weatherManager.js"></script>
		<script src="/ui/map/weatherDiscMan.js"></script>
		<script src="/ui/map/faultDiscMan.js"></script>
		<script src="/ui/map/faultChartMan.js"></script>
		<script src="/ui/map/mapForServer.js?v=0.0.1"></script>
		<script src="/ui/map/riskEvaluate.js"></script>
		<script src="/ui/map/dailyFaultMan.js?v=0.0.3"></script>
		<script src="/ui/map/weatherHistoryMan.js"></script>
		<script src="/ui/map/protectionStatusMan.js"></script>
		<script src="/ui/map/typhoonDiscMan.js?v=0.0.0"></script>
		<script src="/ui/map/typhoonForecastMan.js?version=0.0.0"></script>
		<script src="/ui/map/riskAlarmMan.js"></script>
		<script src="/ui/map/protectionStatusEvaluation.js"></script>
		<script src="/ui/map/realTimeAnimator.js"></script>
		<script src="/ui/map/typhoonSvg/typhoonTimeLine.js"></script>
		<script src="/ui/map/iceWarningManager.js?version=0.0.0"></script>
		<script src="/ui/map/thunderWarningManager.js"></script>
		<script src="/ui/map/travelingFaultDisc.js"></script>
		<script>
		/* 	$("body").addClass("sidebar-collapse");
			$(".main-sidebar").addClass(".sidebar-mini .sidebar-collapse"); */
		//	$("#weaterhNum").text(weatherData.length);
			var localeTitle = {
					mingXi:'#{lang.mingXi}',
					search:'#{lang.souSuoAnNiu}',
					ChaXunShiJianBuChaoGuo:'#{lang.ChaXunShiJianBuChaoGuo}',
					Tian:'#{lang.Tian}',
					ChaXunKaiShiShiJianBuChaoGuoJieShuShiJian:'#{lang.ChaXunKaiShiShiJianBuChaoGuoJieShuShiJian}',
					ChaXunShiJianBuBiaoZhun:'#{lang.ChaXunShiJianBuBiaoZhun}',
					ZuoTian:'#{lang.ZuoTian}',
					QianSanTian:'#{lang.QianSanTian}',
					QianSiTian:'#{lang.QianSiTian}',
					QianBaTian:'#{lang.QianBaTian}',
					daily:{
					 BaoHuRiBao : '#{lang.BaoHuRiBao}',
					 GuZhangRiBao : '#{lang.GuZhangRiBao}',
					 BaoHuQueXian : '#{lang.BaoHuQueXian}',
					 BaoHuQueXianJiChuLi : '#{lang.BaoHuQueXianJiChuLi}',
					 BaoHuJianXiu : '#{lang.BaoHuJianXiu}',
					 QuanBu :'#{lang.QuanBu}',
					 YiWanGong : '#{lang.YiWanGong}',
					 JinXingZhong : '#{lang.JinXingZhong}',
					 DaiKaiGong : '#{lang.DaiKaiGong}',
					 JieZhi : '#{lang.JieZhi}',
					 TongDaoJianShi : '#{lang.TongDaoJianShi}',
					 BaoHuTongDaoZhongDuan : '#{lang.BaoHuTongDaoZhongDuan}',
				 	 BaoHuTongDaoPinFanZhongDuan : '#{lang.BaoHuTongDaoPinFanZhongDuan}', 
					 ShuangTongDaoZhongDuan : '#{lang.ShuangTongDaoZhongDuan}',
					 BaoHuFengXian : '#{lang.BaoHuFengXian}',
					 SheBeiQiDong : '#{lang.SheBeiQiDong}',
					 ZhuanXiangHuiBao : '#{lang.ZhuanXiangHuiBao}'
					 },
					fault:{
					GuZhangSheBei:'#{lang.GuZhangSheBei}',
					GuZhangShiJian:'#{lang.GuZhangShiJian}',
					GuZhangLeiXing:'#{lang.GuZhangLeiXing}',
					WuGuZhangFaSheng:'#{lang.WuGuZhangFaSheng}',
					ZhuWangGongFaSheng:'#{lang.ZhuWangGongFaSheng}',
					QiTiaoZhaShiJian:'#{lang.QiTiaoZhaShiJian}'
					},
				    defect:{
				    ChangZhanMingCheng:'#{lang.ChangZhanMingCheng}',
				    BaoHuMingCheng:'#{lang.BaoHuMingCheng}',
				    BaoHuTuiChuShiJian:'#{lang.BaoHuTuiChuShiJian}',
				    WuQueXianJiLu:'#{lang.WuQueXianJiLu}'
					 },
					channel:{
						XianLu:'#{lang.XianLu}',
						BaoHu:'#{lang.BaoHu}',
						PinFanCiShu:'#{lang.PinFanCiShu}',
						ShiJian:'#{lang.ShiJian}',
						WuTongXinZhongDuanYiChang:'#{lang.WuTongXinZhongDuanYiChang}',
						WeiFaShengBaoHuTongDaoPinFanZhongDuan:'#{lang.WeiFaShengBaoHuTongDaoPinFanZhongDuan}',
						WeiFaShengShuangTongDaoTongShiZhongDuan:'#{lang.WeiFaShengShuangTongDaoTongShiZhongDuan}',
						BaoHuTongXiZhongDuanFaSheng:'#{lang.BaoHuTongXiZhongDuanFaSheng}',
						Ci:'#{lang.Ci}',
						GongJi:'#{lang.GongJi}',
						XiaoShi:'#{lang.XiaoShi}'
					}
			}
			
			 function showNewEquipmentAlarmMsg() {
			 	MyModal.showModal("/ui/message/cimEquipmentUpdateMsg.xhtml");
			 }
			 
			function changeStatus(obj){
				if($('#collapseBtn').attr('class')=='btn-collapse'){
				}else{
					$('#myLogo').removeAttr('src');
					$('#myLogo').css('width', 0);
					$('#myLogo').css('height', 0);
					$('#collapseBtn').removeClass('btn-collapse-min');
					$('#collapseBtn').addClass('btn-collapse');
				}
			}
			$('#btnBoxLeft').on('hidden.bs.collapse', function () {
					$('#myLogo').attr('src', 'resources/img/message/mylogo.png');
					$('#myLogo').css('width', 20);
					$('#myLogo').css('height', 20);
					$('#collapseBtn').removeClass('btn-collapse');
					$('#collapseBtn').addClass('btn-collapse-min');
			})
			function openDialog(dlgParam){
				//console.log(dlgParam);
				var url = dlgParam.url;
				var contentWidth = dlgParam.width;
				var contentHeight = dlgParam.height;
				var urlparams = dlgParam.urlParams;
				if(typeof urlparams == 'string'){
					urlparams=JSON.parse(urlparams);
				}
				if(urlparams){
					if(urlparams.length > 0){
						var up = "";
						for(var i in urlparams){
							if(i == 0){
								up += (urlparams[i].name+"="+urlparams[i].value);
							}else{
								up += ("&amp;"+urlparams[i].name+"="+urlparams[i].value);
							}
						}
						url += "?"+up;
					}
				}
				MyModal.showModal(url,contentWidth,contentHeight);
			}
			//TODO 
			//1.判断map是否有，或者判断是否报错
			
			//2.如果有，调用mapforserver.js中的init();
			//3.如果没有，启动异常处理机制，调用mapforserverException.js中的加载方法
			init(); 
			document.onkeydown = function (e) {
	            var theEvent = window.event || e;
	            var code = theEvent.keyCode || theEvent.which;
	            if (code == 13) {
	            	var str = $("#input_search").val();
	            	if(str.length > 0)
	                	$("#btn_search").click();
	            }
	        }
			$(function(){
				if(localStorage.getItem('enlarge')){
			 		var url = '/resources/css/map/enlarge/map-enlarge-font.css';
			 		var head = document.getElementsByTagName('head')[0];
			        var link = document.createElement('link');
			        link.type='text/css';
			        link.rel = 'stylesheet';
			        link.href = url;
			        link.id = "enlargeCss";
			        head.appendChild(link);
				}
				showNewEquipmentAlarm();
			});
			//地图--切换显示横竖工具条
			//transverseBtnBox
			//btnBox
			/* function changePortraitAndTransverseBtnBox() {
				var transverseBtnBox = $('#transverseBtnBox');
				var btnBox = $('#btnBox');
				if (transverseBtnBox.isshow()) {
					transverseBtnBox.hide();
					btnBox.show();
				} else {
					transverseBtnBox.shpw();
					btnBox.hide();
				}
			} */
		</script>

	</ui:define>
</ui:composition>
